Reading ICD2Vec

all_icd <- fread("../data/cad_pred_new2/ICD_Code_Vectors.csv", header = TRUE, data.table=FALSE)
colnames(all_icd)[3:302] <- paste0("V", 1:300)
all_icd <- all_icd[,-1]
all_icd <- rename(all_icd, DIS_NAME = DIS_CODE)
nrow(all_icd)
## [1] 19154

3D Plotting after PCA

2D Plotting after PCA

## No trace type specified:
##   Based on info supplied, a 'scatter' trace seems appropriate.
##   Read more about this trace type -> https://plotly.com/r/reference/#scatter
## No scatter mode specifed:
##   Setting the mode to markers
##   Read more about this attribute -> https://plotly.com/r/reference/#scatter-mode
## Warning in RColorBrewer::brewer.pal(N, "Set2"): n too large, allowed maximum for palette Set2 is 8
## Returning the palette you asked for with that many colors

## Warning in RColorBrewer::brewer.pal(N, "Set2"): n too large, allowed maximum for palette Set2 is 8
## Returning the palette you asked for with that many colors